#include <iostream>
#include <string>

class RentHouse
{
public:
    virtual void renthouse() = 0;
};
class Landlord : public RentHouse
{
public:
    void renthouse()
    {
        std::cout << "租房" << std::endl;
    }
};
class Agency : public RentHouse
{
public:
    void renthouse()
    {
        std::cout << "发布租房信息" << std::endl;
        std::cout << "带人看房" << std::endl;
        _landlord.renthouse();
        std::cout << "提供租后服务" << std::endl;
    }
private:
    Landlord _landlord;
};
int main()
{
    Agency agency;
    agency.renthouse();
    return 0;
}